V = Variable
R = Reading functions
The VR10LngtoWrd function breaks up a LONG variable into two variables of Word.
The function is passed the Long variable that will be broken up into two variables word: “Word high part” and “Word low part”.
VR10LngtoWrd (slLong,swWordUp,swWordDw)
Parameters:
| IN/OUT | VARIABLE TYPE | EXAMPLE NAME | DIM | |
|---|---|---|---|---|
| IN | SYSTEM / GLOBAL | SlLong | L | Long variable by break up |
| OUT | SYSTEM / GLOBAL | SwWordUp | W | Word that represents the UPPER part of the Long |
| OUT | SYSTEM / GLOBAL | SwWordDw | W | Word that represents the LOWER part of the Long |
MAIN: slLong = AnAsse:setpos ;Carica il setpos di un device sulla Long da scomporre VR10LngtoWrd (slLong,swWordUp,swWordDw) ;Scompone la variabile Long aswBuffer[200] = swWordDw ;Imposta Parte bassa sul Buffer aswBuffer[201] = swWordUp ;Imposta Parte alta sul Buffer ...... ..... END